<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <script src="../vue.js"></script>
</head>

<body>
  <div id="app">
    <div>
      <button @click="type = 1">新闻</button>
      <button @click="type = 2">体育</button>
      <button @click="type = 3">音乐</button>
      <button @click="type = 4">电影</button>
    </div>
    <div>
      <!-- v-show也是需要接收一个boolean 决定当前元素时display：none还是block -->
      <ul v-show="type===1">
        <li>李博昨晚.....</li>
        <li>李博前天晚上.....</li>
        <li>李博明天晚上肯定.....</li>
      </ul>
      <ul v-show="type===2">
        <li>李博扣篮</li>
        <li>李博连续扣篮</li>
        <li>李博连续被扣</li>
      </ul>
      <ul v-show="type===3">
        <li>七里香</li>
        <li>李博香</li>
      </ul>
      <ul v-show="type===4">
        <li>李博大战小菜鸡</li>
        <li>李博大战小趴菜</li>
        <li>李博大战奥特曼</li>
      </ul>
    </div>
  </div>
  <script>
    Vue.config.productionTip = false;

    const vm = new Vue({
      el: "#app",
      data() {
        return {
          type: 1
        }
      }
    })
  </script>
</body>

</html>